<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8">
		<link rel="stylesheet" href="css/style.css">
		<title>Your Contribution</title>
	</head>
	<body onload="load();">
		
	</body>
	<script>
			// Aqui eu estou criando a Tag Canvas no HTML ao invés de criar em HTML
		var canvas = document.createElement("canvas");
		
		canvas.width = 800; //Setando o width do canvas
		canvas.height = 600; //Setando o height do canvas

		ctx = canvas.getContext("2d"); //Adicionando o context 2D do canvas na variável ctx

		document.body.appendChild(canvas); //Adicionando ele no canvas

	</script>
	
	<script src="js/physics/Collider.js"></script>
	<script src="js/system/Sprite.js"></script>
	<script src="js/level/Breed.js"></script>
	<script src="js/eventListener/MouseEventListener.js"></script>
	<script src="js/eventListener/KeyboardEventListener.js"></script>
	<script src="js/system/Button.js"></script>
	<script src="js/scene/MenuScene.js"></script>
	<script src="js/level/One.js"></script>
	<script src="js/manager/LevelManager.js"></script>
	<script src="js/scene/GameScene.js"></script>
	<script src="js/scene/CreditsScene.js"></script>
	<script src="js/manager/SceneManager.js"></script>
	<script src="js/system/GameBehavior.js"></script>

	<script>

		//Atribuindo as cenas
		var SCENE = {MENU: 0, GAME: 1, CREDITS: 2};
		var currentScene = SCENE.MENU;
		var scene = null;

		//Atribuindo os leveis do jogo
		var LEVEL = {INTRO: 0, ONE: 1, TWO: 2, THREE: 3, FOUR: 4, FIVE: 5};
		var currentLevel = LEVEL.ONE;
		var level = null;

		//Adicionando evento ao jogo
		/*==== EVENTO DE TECLADO =====*/
		var KEY = {ONE: 49, TWO: 50, THREE: 51, FOUR: 52, FIVE: 53};

		document.addEventListener("keydown", KeyboardEventListener.down, true);
		document.addEventListener("keyup", KeyboardEventListener.up, true);

		/*==== EVENTO DE MOUSE =====*/
		var mouseButton = {LEFT: 1, MIDDLE: 2, RIGHT: 3};
		var mousePosition = {x: 0, y: 0};
		var mousePressed = {LEFT: false, MIDDLE: false, RIGHT: false};

		document.addEventListener("mousedown", MouseEventListener.down, true);
		document.addEventListener("mouseup", MouseEventListener.up, true);
		document.addEventListener("mousemove", MouseEventListener.move, true);

	</script>
</html>